﻿@model Pr0ject0.Models.JobModel

@{
    ViewBag.Title = "AddJob";
}

<br />

<div class="button" >
    @Html.Partial("~\\Views\\Shared\\_PartialLogout.cshtml")
</div>

<br />

@using (Html.BeginForm()) {
    @Html.ValidationSummary(false)

    <fieldset>
        <legend>Add Job Details</legend>
        <table>
        @Html.HiddenFor(model => model.departmentId)
        @Html.HiddenFor(model => model.storeId)
        
            <div class="editor-label">
                <tr>
                    <th>@Html.LabelFor(model => model.title)</th>
                    <th>@Html.LabelFor(model => model.salary)</th>
                </tr>
            </div>
            <div class="editor-field">
                <tr>
                        <td>@Html.DropDownListFor(model => model.title , new SelectList(Model.jobTitles, "Key", "Value"))</td>
                        <td>@Html.EditorFor(model => model.salary)</td>
                        <td>@Html.ValidationMessageFor(model => model.title)</td>
                </tr>
            </div>
        </table>
        
        <br />

        <p>
            <input type="submit" value="Submit" />
        </p>
    </fieldset>
}

<div class="button">
    @Html.ActionLink("Cancel", "Jobs")
</div>

@section Scripts {
    @Scripts.Render("~/bundles/jqueryval")
}
